<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>

<%@ taglib uri="http://tiles.apache.org/tags-tiles" prefix="tiles"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
request.setAttribute("basePath", basePath);

String outPatientZtqkInfoJson= (String)request.getAttribute("outPatientZtqkInfoJson");
String success= (String)request.getAttribute("success");
%>
<link href="${basePath}/static/css/Pigeonhole/Pigeonhole_list.css"
	rel="stylesheet" type="text/css">
<link rel="stylesheet"
	href="${basePath}/static/css/medicalRecord_Search/medicalSearch.css" />
<script type="text/javascript"
	src="${basePath}/static/publics/assets/jqPaginator/jqPaginator.js"></script>
	<script type="text/javascript" src="${basePath}assets/js/echarts.js"></script>
<div class="list_NR">
<div class="loc">
            <h3>绩效考核</h3>
            <ul class="loc_loc">总体情况
            </ul>
        </div>
        
        <div class="list_con_table">
	        	<div class="search_table">
                <ul class="clearfix" style="margin-bottom:0;">
                		
                    <li class="Label_5">
                        <div class="right">
                        	<input class="btn" type="button" onclick="exportMzZtqkWord()" value="导出">
                        	<input class="btn" type="button" onclick="saveOutPatientZtqk()" value="保存">
                        </div>
                    </li>
                    <li class="Label_1" style="width:12%;height:200px;line-height:100px">说明：&nbsp;</li>
                    <li class="Label_2" style="width:17%;height:200px"><textarea style="height:200px;width:517%"/>${outPatientZtqkInfo.note}</textarea></li>
                </ul>
            </div>
        </div>
       
        <table class="Search_tableList" cellpadding="0" cellspacing="0">
       		  <tr>
                <td class="tdLabel_5" colspan="10">
                	<div id="container2" style="height: 400px;width:100%"></div>
                </td>
     		 <tr>
             
            </tbody>
               
           
        </table>



</div>
	





<script>

var myChart2 ;

function exportWord(){
  window.location.href="${basePath}/report/exportGeneralPerformanceWord";
}


function exportMzZtqkWord(){
	 var base64info = myChart2.getDataURL();
	 $.ajax({
	  type:"post",
	  data:{image:base64info,method:'getImage'},
	  url:"${basePath}/report/exportMzZtqkWord",
	  success:function(data){
	     window.location.href ="${basePath}/report/exportMzZtqkWord?method=export";
	  }
	})
	 
	 }

//保存
function saveOutPatientZtqk(){
	 var base64info = myChart2.getDataURL();
   $.ajax({
       type:"post",
       data:{ztqkImgBase64:base64info},
        url:"${basePath}/report/saveOutPatientZtqk",
        success:function(data){
        	layer.alert(data.msg,{icon:1});
        }
   });
	

}


//初始化图表信息
$(function(){
	var outPatientZtqkInfoJson= <%=outPatientZtqkInfoJson%>;
	
	console.log(outPatientZtqkInfoJson);
	if(null!=outPatientZtqkInfoJson){
		initCharset2(outPatientZtqkInfoJson);
	}
	
});


function initCharset2(params){
	var dom = document.getElementById("container2");
	myChart2 = echarts.init(dom);
	var app = {};
	option = null;
	app.title = '折柱混合';

	option = {
		tooltip: {
   		trigger: 'axis',
  			 axisPointer: {
     			  type: 'cross',
       			crossStyle: {
           		color: '#999'
      				 }
   		}
		},

	legend: {
	    y: 'bottom',
   	data:params.monthList
		 },
	xAxis: [
   {
       type: 'category',
       data: ['门急诊量','门诊量','急诊量'],
       axisPointer: {
           type: 'shadow'
       },
		textStyle: {
			fontSize: 10
		}
   }
		 ],
	  yAxis: [
  	 {
       type: 'value',
       name: '人次数',
    /*    min: 0,
       max: params.totalNum,
       interval: params.avgNum, */
       axisLabel: {
           formatter: '{value}'
       }
   }
	 ],
series: [
   {
       name:params.monthList[0],
       type:'bar',
       data:params.param1List
   },
   {
       name:params.monthList[1],
       type:'bar',
       data:params.param2List
   },
	{
       name:params.monthList[2],
       type:'bar',
       data:params.param3List
   }
	
	
 
]
};
;
if (option && typeof option === "object") {
	  myChart2.setOption(option, true);
}
}






</script>